import Vue from "vue";
import App from "./App.vue";
//引入mock
import "../api/mock";
//按需引入element-ui
import {
  Button,
  Table,
  TableColumn,
  Form,
  FormItem,
  Input,
  Select,
  Switch,
  Option,
  Dialog,
  MessageBox,
  Message,
} from "element-ui";
import "element-ui/lib/theme-chalk/index.css";

//axios
import axios from "axios";

Vue.config.productionTip = false;
//按需使用
Vue.use(Button);
Vue.use(Table);
Vue.use(TableColumn);
Vue.use(FormItem);
Vue.use(Form);
Vue.use(Input);
Vue.use(Select);
Vue.use(Switch);
Vue.use(Option);
Vue.use(Dialog);

//应用axios等
Vue.prototype.$http = axios;
Vue.prototype.$confirm = MessageBox.confirm;
Vue.prototype.$message = Message;

new Vue({
  render: (h) => h(App),
}).$mount("#app");
